#include "componentsPlugin.h"

#include <qqml.h>

void componentsPlugin::registerTypes(const char* uri)
{
    // 建议cpp 和qml 文件的item都进行注册
    qmlRegisterType(QUrl("qrc:/qml/controls/CCButton1.qml"), uri, 1, 0, "CCButton1");
    qmlRegisterType(QUrl("qrc:/qml/controls/CCColoredImage.qml"), uri, 1, 0, "CCColoredImage");
    qmlRegisterType(QUrl("qrc:/qml/controls/CCGradientImage.qml"), uri, 1, 0, "CCGradientImage");
    qmlRegisterType(QUrl("qrc:/qml/controls/CCHoverHoriButton.qml"), uri, 1, 0, "CCHoverHoriButton");
    qmlRegisterType(QUrl("qrc:/qml/controls/CCLabel.qml"), uri, 1, 0, "CCLabel");
    qmlRegisterType(QUrl("qrc:/qml/controls/CCMenuButton.qml"), uri, 1, 0, "CCMenuButton");
    qmlRegisterType(QUrl("qrc:/qml/controls/CCRadioButton.qml"), uri, 1, 0, "CCRadioButton");
    qmlRegisterType(QUrl("qrc:/qml/controls/CCTextField.qml"), uri, 1, 0, "CCTextField");
}
